//
//  sectionOneCell.m
//  DimComDemo
//
//  Created by 于跃隆 on 2019/1/29.
//  Copyright © 2019 于跃隆. All rights reserved.
//

#import "sectionOneCell.h"

@implementation sectionOneCell

-(void)setSectionCell:(ShopOne *)one{
    if (one) {
        //设置imagebtn的背景图片
        [self.imageBtn setBackgroundImage:[UIImage imageWithData:[NSData dataWithContentsOfURL:[NSURL URLWithString:one.masterPic]]] forState:UIControlStateNormal];
        //设置主标题
        self.titleLabel.text = [NSString stringWithFormat:@"%@",one.commodityName];
        //设置价格标题
        self.priceLabel.text = [NSString stringWithFormat:@"¥%.2ld",one.price];
        //设置按钮的边框
        self.BacBtn.layer.borderWidth = 1;
        //设置按钮的边框颜色
        self.BacBtn.layer.borderColor = [UIColor lightGrayColor].CGColor;
    }
}

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
}

@end
